<template>
  <div class="shareSheet">
<button @click="showShare = true" >点我</button>
    <van-share-sheet
      v-model="showShare"
      :options="options"
      title="立即分享给好友"
      description="描述信息"
    />


  </div>
</template>

<script>
import { Toast } from 'vant';
export default {
  data() {
    return {
      showShare: false,
      options: [
        { name: "微信", icon: "wechat" },
        { name: "微博", icon: "weibo" },
        { name: "复制链接", icon: "link", description: "描述信息" },
        { name: "分享海报", icon: "poster" },
        { name: "二维码", icon: "qrcode" },
      ],
    };
  },
  methods: {
    onSelect(option) {
      Toast(option.name);
      this.showShare = false;
    },
  },
};
</script>

<style scoped>

.shareSheet{
    height: 150px;
}
van-share-sheet{
    height: 1.5rem;
    position: fixed;
    bottom: 1rem;
}
</style>